﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Assignment_3.Feature___Users
{
    public partial class Logout : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["username"] == null)
            {
                Response.Redirect("~/Feature - Users/Login.aspx");
            }
        }

        protected void yesBtn_Click(object sender, EventArgs e)
        {
            Session["username"] = null;
            Session["usertype"] = null;
            Session.Abandon();
            Response.Redirect("~/Feature - Users/Login.aspx");
        }

        protected void noBtn_Click(object sender, EventArgs e)
        {
            Response.Redirect("~/Feature - Reports/OverviewReport.aspx");
        }
    }
}